package com.zkadmin.controller;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.zkoss.zk.ui.select.annotation.Wire;
import org.zkoss.zul.Panel;
import org.zkoss.zul.Row;
import org.zkoss.zul.Window;

import com.zkadmin.entity.SysSetting;
import com.zkadmin.helper.ZkAdminInit;

@SuppressWarnings("serial")
public class LoginCtrl extends BaseCtrl<Window> {
	Logger logger = LoggerFactory.getLogger(LoginCtrl.class);

	@Wire
	private Row rememberMeRow;

	@Wire
	private Panel loginPanel;

	private SysSetting setting;

	@Override
	protected void init(Window win) {
		setting = ZkAdminInit.getSetting();
		loginPanel.setTitle(setting.getName());
		rememberMeRow.setVisible(setting.getRememberMe());
	}
}
